package cn.itsource.autoconfigure;

import cn.itsource.config.SmsProperties;
import cn.itsource.core.SmsTemplate;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
@EnableConfigurationProperties(value = SmsProperties.class)
public class SmsAutoConfiguration {

    @Bean
    public SmsTemplate getSmsTemplate(SmsProperties smsProperties){
        return new SmsTemplate(smsProperties);
    }
}
